<!-- 轮播图列表 -->
<template>
  <div class="slide_list">
     <CurrencyList :title="title" :slide="slide" :path="path" />
  </div>
</template>

<script lang='ts'>
import { defineComponent, reactive, toRefs } from 'vue';
import CurrencyList from '../../components/CurrencyList.vue';

export default defineComponent({
  name: 'SlideList',
  components: { CurrencyList },
  setup () {
    const data = reactive({
      title: '轮播图列表',
      // 表格的标题
      slide: [
        { name: '_id', label: '_id' },
        { name: 'article_id.title', label: '文章标题' },
        { name: 'classification', label: '类别'}
      ],
      path: 'slides', // 请求的路径
    });

    const refData = toRefs(data);

    return { 
      ...refData
    }
  }
})
</script>

<style lang="scss" scoped>
.slide_list {
  .el-table__body {
    // 设置表格图片的大小
    img {
      width: 100%;
    }
  }
  .p {
    color:rgb(0, 110, 255);
    margin-right: 20px;
    cursor: pointer;
  }
}
</style>